package com.wn.sddfp.gateway.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;
import java.util.Map;

/**
 * 网关出现问题 进行服务降级
 */
@RestController
public class FallbackController {

    @GetMapping("/fallback")
    public Map<String,Object> fallback(){
        Map<String,Object> map = new HashMap<>();
        map.put("code",500);
        map.put("message","服务不可用");
        return map;
    }
}